package cn.estart.demo.springboot.first.controller;

import cn.estart.demo.springboot.first.config.ConfigBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.RequestMapping;

@RestController
public class HelloController {

    @Autowired
    ConfigBean config;
    @RequestMapping("/")
    public String index() {
        System.out.println(config.getName());
        return "Greetings from Spring Boot!";
    }

}